package com.chart.web.controller.chart;


import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.chart.common.core.domain.AjaxResult;
import com.chart.system.domain.RegistrationChannels;
import com.chart.system.service.RegistrationChannelsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;
/**
 * 用户来源
 * @author 罗继全
 * 2024/9/12 14:26
 */
@RestController
@RequestMapping("/registration/channel")
public class RegistrationChannelController {

    @Autowired
    RegistrationChannelsService registrationChannelsService;

    /**
     * 来源查询
     * @return
     */
    @GetMapping("query/list")
    public AjaxResult querylist(){
        LambdaQueryWrapper<RegistrationChannels> lqw = new LambdaQueryWrapper<>();
        lqw.eq(RegistrationChannels::getStatus,0);
        List<RegistrationChannels> list = registrationChannelsService.list(lqw);
        return AjaxResult.success(list);
    }
}
